<?php
	$db = ADONewConnection($dbdriver);
	$db->Connect($server, $user, $password, $database);
	$db->SetFetchMode(ADODB_FETCH_ASSOC);

    $db->debug = false;
	
	$sql = 'select distinct bloque from plano order by 1';
    $rs = $db->Execute($sql);
    $data = $rs->GetRows();    

    foreach ($data as $data_) 
		echo "<option value=\"{$data_['bloque']}\" >{$data_['bloque']}</option>";

	$db->Close(); 
?>